import service from "./service";
import qs from 'QS';
let link = ((url: any,method="GET",data={},params={})=>{
    return new Promise((resolve,reject)=>{
        service.request({
            url,
            method,
            data,
            params
        }).then((ok: any)=>{
            resolve(ok)
        }).catch((err: any)=>{
            reject(err)
        })
    })
})

export default link